The present invention relates to a motor controller for controlling a motor and a method for duty-controlling a motor when driving the motor, and more particularly, to control of a motor for opening and closing a door window glass of a vehicle.
A first prior art example of a power window apparatus controls the raising and lowering speed of a door window glass by controlling the duty ratio of the voltage applied to a motor for opening and closing the door window glass. The power window apparatus lowers the travel speed of the door window glass when the door window glass approaches a fully closed position or a fully open position. This reduces the noise generated when the door window glass comes in contact with the door frame.
The travel speed of the door window glass may be decreased as the door window glass approaches the fully closed position or the fully open position. In this speed decreasing control, the motor torque is reduced. As a result, the door window glass may not reach the fully closed position or the fully open position.
A second prior art example of a power window apparatus increases the duty ratio of a motor drive signal just before the door window glass reaches the fully closed position to increase the motor torque when raising the door window glass (refer to Japanese Laid-Open Patent Publication No. 2002-327574).
When the motor torque is increased just before the door window glass reaches the fully closed position, the door window glass may strike the door frame and produce a relatively large noise.